#!/usr/bin/expect

spawn scp -o StrictHostKeyChecking=no /home/honway/code/robot-client/target/robot-client-1.0.0.jar manager@192.168.50.51:~/robot/robot_client/logs/
expect "password:"
send "123456\r"

spawn ssh -o "StrictHostKeyChecking no" manager@192.168.50.51
expect "password:"
send "123456\r"
expect "root"
send "cd ~/robot/robot_client/\r"
interact